package com.tvunetworks.center.user.model.param;

import com.tvunetworks.center.user.constant.UserConstant;
import lombok.Data;

import java.util.ArrayList;
import java.util.List;

/**
 * @program: -
 * @description: -
 * @author Ethan
 * @create: 2021/8/4 19:41
 **/
@Data
public class PageInfoRByBookMarkParam {

    private  String bookmarkId;

    private String sourceId;

    private String search;

    private boolean online;
    private boolean live;
    private boolean offline;

    private Integer pageSize;

    private Integer pageNum;

    /**
     *
     * @return List
     */
    public List<String> getStatus(){
        List<String> list = new ArrayList<>();
        if (live) {
            list.add(UserConstant.DeviceStatus.LIVE);
        }
        if (online) {
            list.add(UserConstant.DeviceStatus.ONLINE);
        }
        if (offline) {
            list.add(UserConstant.DeviceStatus.OFFLINE);
        }
        return list;
    }
}
